package com.ifp.opengate.boot.bean.access;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Component;

@Component
public class AppWhiteListBean {

    private Map<String, List<Map<String, Object>>> whitelist = new HashMap<>();

    public Map<String, List<Map<String, Object>>> getWhitelist() {
        return whitelist;
    }

    public void setWhitelist(Map<String, List<Map<String, Object>>> whitelist) {
        this.whitelist = whitelist;
    }

    /***
     * 设置一个应用的白名单list
     */
    public void setWhiteListItem(String key, List<Map<String, Object>> value) {
        whitelist.put(key, value);
    }

    /**
     * 获取一个应用list
     **/
    public List<Map<String, Object>> getWhiteListItem(String key) {
        return whitelist.get(key);
    }

}
